#ifndef _DICOM_STORAGE_DECRYPT_H_
#define _DICOM_STORAGE_DECRYPT_H_

#include "dicom/storage/stream.h"
#include "dicom/upload/hash_cache.h"

namespace dicom {

class Decryptor {
 public:
  Decryptor() {}
  ~Decryptor() {}

  Status DoDecrypt(const std::string& hex_key, ReaderStream* src,
                   WriterStream* out);

  Status DoDecryptAndHash(const std::string& hex_key, ReaderStream* src,
                          WriterStream* out, HashEntry* hash);
};

Status DecryptAndUnzipFile(const std::string& hexkey,
                           const std::string& src_file,
                           const std::string& dest_file);

Status DecryptAndUnzipFileAndHash(const std::string& hexkey,
                                  const std::string& src_file,
                                  const std::string& dest_file,
                                  HashEntry* hash);
}

#endif  // _DICOM_STORAGE_DECRYPT_H_
